package com.ibeetl.cms.entity;

import com.ibeetl.admin.core.annotation.Dict;
import com.ibeetl.admin.core.entity.BaseEntity;
import com.ibeetl.admin.core.util.ValidateConfig;
import com.ibeetl.admin.core.util.enums.CoreDictType;
import org.beetl.sql.core.annotatoin.AutoID;
import org.beetl.sql.core.annotatoin.SeqID;
import org.beetl.sql.core.annotatoin.UpdateIgnore;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.util.Date;

/**
 * 系统栏目
 */
public class CmsCatalog extends BaseEntity {

    public static final String TYPE_SYSTEM = "CATALOG_S";
    public static final String TYPE_NAV = "CATALOG_N";
    public static final String TYPE_CATALOGITEM = "CATALOG_M";

	@SeqID(name = ORACLE_CORE_SEQ_NAME)
	@AutoID
    protected Long id;

    //创建时间
	@UpdateIgnore
    protected Date createTime;

    //栏目代码
    @NotBlank(message = "栏目代码不能为空", groups = ValidateConfig.ADD.class)
    private String code;

    //功能id
    private Long functionId;
    
    private String keywords;
    private String description;
    private String descriptionEn;
    private String descriptionIt;

    private Long articleFunctionId;
    private Long articleListFunctionId;

    //类型  /*1 系统 2 导航 3 栏目项(与功能点有关)*/
    @Dict(type = CoreDictType.CATALOG_TYPE)
    private String type;

    //栏目名称
    @NotBlank(message = "栏目名称不能为空")
    private String name;

    private String nameEn;
    private String nameIt;

    //上层栏目id
    @NotNull(message = "上层栏目不能为空")
    private Long parentCatalogId;

    //排序
    @NotNull(message = "排序不能为空")
    private Integer seq;

    //图标
    private String icon;
    
    private String content ;
    private String contentEn;
    private String contentIt;
    
    private String seoTitle;
    private String seoKeyword;
    private String seoDesc;
    
    private String position;
    
    private String attachmentId;
    private String imageId;
    public CmsCatalog() {
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public Long getFunctionId() {
        return functionId;
    }

    public void setFunctionId(Long functionId) {
        this.functionId = functionId;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public Long getParentCatalogId() {
        return parentCatalogId;
    }

    public void setParentCatalogId(Long parentCatalogId) {
        this.parentCatalogId = parentCatalogId;
    }

    public Integer getSeq() {
        return seq;
    }

    public void setSeq(Integer seq) {
        this.seq = seq;
    }

    public String getIcon() {
        return icon;
    }

    public void setIcon(String icon) {
        this.icon = icon;
    }

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public String getAttachmentId() {
		return attachmentId;
	}

	public void setAttachmentId(String attachmentId) {
		this.attachmentId = attachmentId;
	}

	public String getContent() {
		return content;
	}

	public void setContent(String content) {
		this.content = content;
	}

	public String getSeoTitle() {
		return seoTitle;
	}

	public void setSeoTitle(String seoTitle) {
		this.seoTitle = seoTitle;
	}

	public String getSeoKeyword() {
		return seoKeyword;
	}

	public void setSeoKeyword(String seoKeyword) {
		this.seoKeyword = seoKeyword;
	}

	public String getSeoDesc() {
		return seoDesc;
	}

	public void setSeoDesc(String seoDesc) {
		this.seoDesc = seoDesc;
	}

	public String getPosition() {
		return position;
	}

	public void setPosition(String position) {
		this.position = position;
	}

	public Long getArticleFunctionId() {
		return articleFunctionId;
	}

	public void setArticleFunctionId(Long articleFunctionId) {
		this.articleFunctionId = articleFunctionId;
	}

	public Long getArticleListFunctionId() {
		return articleListFunctionId;
	}

	public void setArticleListFunctionId(Long articleListFunctionId) {
		this.articleListFunctionId = articleListFunctionId;
	}

	public String getKeywords() {
		return keywords;
	}

	public void setKeywords(String keywords) {
		this.keywords = keywords;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}
    public String getImageId() {
        return imageId;
    }

    public void setImageId(String imageId) {
        this.imageId = imageId;
    }

    public String getNameEn() {
        return nameEn;
    }

    public void setNameEn(String nameEn) {
        this.nameEn = nameEn;
    }

    public String getNameIt() {
        return nameIt;
    }

    public void setNameIt(String nameIt) {
        this.nameIt = nameIt;
    }

    public String getContentEn() {
        return contentEn;
    }

    public void setContentEn(String contentEn) {
        this.contentEn = contentEn;
    }

    public String getContentIt() {
        return contentIt;
    }

    public void setContentIt(String contentIt) {
        this.contentIt = contentIt;
    }

    public String getDescriptionEn() {
        return descriptionEn;
    }

    public void setDescriptionEn(String descriptionEn) {
        this.descriptionEn = descriptionEn;
    }

    public String getDescriptionIt() {
        return descriptionIt;
    }

    public void setDescriptionIt(String descriptionIt) {
        this.descriptionIt = descriptionIt;
    }
}
